package com.tdb.web;

import com.tdb.mapper.TestMapper;
import com.tdb.mapper.TestService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.transaction.annotation.Propagation;
import org.springframework.transaction.annotation.Transactional;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

/**
 * @author: LCG
 * 作者: LCG
 * 日期: 2021/4/6  14:26
 * 描述:
 */

@RestController
public class TestController {

    @Autowired
    private TestService testService;

    @RequestMapping("tableLock1")
    public int testMapper1() throws InterruptedException {
        int i = testService.testMapper1();

        return i;
    }


    @RequestMapping("tableLock2")
    public int testMapper2(){
        int i = testService.testMapper2();

        return i;
    }

}
